# 基础 openresty 镜像
FROM bolingcavalry/ubuntu16-openresty:0.0.1
# 定义作者
MAINTAINER hudan <hudan@mfexcel.com>
# 清除原有 nginx.conf
RUN rm -f /usr/servers/nginx/conf/nginx.conf

# 设定工作目录
WORKDIR /usr/servers/nginx

# 拷贝指定文件
COPY nginx.conf /usr/servers/nginx/conf/
COPY ips_control.conf /usr/local/work/
COPY *.lua /usr/local/work/lualib/

# 日志目录 /usr/servers/nginx/logs
#./usr/servers/nginx/logs/error.log
#./usr/servers/nginx/logs/access.log

# 支持配置环境变量
#ENV ENV_REDIS_DB_INDEX="15" ENV_REDIS_IP="172.17.0.3" ENV_REDIS_PASS="0" ENV_REDIS_PORT="6379" ENV_REDIS_KEY_WHITE_IPS="unite:app:white:ips"